package testCases;

import com.imagotag.test.LabelIdProvider;
import com.imagotag.test.TestEnvironment;

/**
 * @projectName: endurance_test
 * @className: Config
 * @description:
 * @author: JLONG
 * @date: 2024/10/21 16:52
 * @version: 1.0
 */
public class TestConfig {
    // 配置固件信息
    public static String mcu = "panchip";
    public static String FW_Version = "3.1.6";
    public static String FW_no = "pvt";

    // 配置测试价签
    // 价签mcu类型，全小写
    public static String[] tags = {"PAN_GUOYING",};                                                         // 筛选符合所有tags的价签
    public static String[] labelsID = {"ED0006B0",};                                                // 价签ID数组
    public static String[] labelTypes = {"2.6 BW", "2.6 BWR",};                                     // 价签类型数组
    public static LabelIdProvider labelsWithTags = test -> test.getLabelsWithTags(tags);            // 根据Tae，生成价签对象
    public static LabelIdProvider labelsWithID = test -> test.getLabelsByLabelId(labelsID);         // 根据LabelID，生成价签对象
    public static LabelIdProvider labelsWithType = test -> test.getLabelsOfLabelType(labelTypes);   // 根据LabelType，生成价签对象
    public static LabelIdProvider labelsForRegister = test -> test.getLabelsUnchecked(labelsID);    // 根据LabelID，生成价签对象，用于注册等
    public static LabelIdProvider allLabels = TestEnvironment::getAllLabels;                        // 获取core service中所有价签
    public static LabelIdProvider onlineLabels = TestEnvironment::getOnlineLabels;                  // 获取core service中所有已上线价签

    // 配置测试环境
    public static String serviceUrl = "http://192.168.1.1:8001";        // CoreService地址
    public static String syncProfile = "NORMAL";                        // NORMAL; SUPER_FAST_RESPONSE; ULTRA_FAST_RESPONSE
    public static String encryption = "noPIN";
    public static String apChannel = "chan_9";                          // AP的信道

    // 配置测试标准
    public static double tgHash = 0.98;                                 // 图片对比相似度阈值
    public static String webCamera = "USB Camera 0";                    // 相机名称
    public static int refreshDu = 30;                                   // 图片刷新等待时间（秒）
    public static double minTemp = 21.50;                               // 采样最低温限值
    public static double maxTemp = 25.50;                               // 采样最高温限值
    public static double resistance = 20.00;                            // 采样内阻限值（新电池）

    // 配置测试数据存储路径
    public static String dataPath = "../testResults/";                  // 数据根目录
    public static String logsPath = dataPath + "Logs/";                 // 日志存储路径
    public static String standardImagePath = dataPath + "STD_IMAGE/";   // 标准图片存储路径
    public static String testImagePath = dataPath + "TEST_IMAGE/";      // 测试图片存储路径
}
